package com.njtoyo.taxi.admin.service.business;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.njtoyo.taxi.admin.mapper.master.entity.BankWithdrawAction;
import com.njtoyo.taxi.admin.mapper.master.entity.DriverWithdraw;
import com.njtoyo.taxi.admin.rest.presenter.business.driver_withdraw.DriverWithdrawListPresenter;
import com.njtoyo.taxi.admin.rest.wrapper.business.driver_withdraw.IndexWrapper;
import com.njtoyo.taxi.admin.rest.wrapper.business.driver_withdraw.UpdateBankInfoWrapper;
import com.njtoyo.taxi.entity.backend.AdminUser;
import com.taxi.entity.common.RestResult;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

public interface DriverWithdrawService extends IService<DriverWithdraw> {
    RestResult<Page<DriverWithdrawListPresenter>> getPage(AdminUser adminUser, IndexWrapper wrapper);

    RestResult<List<BankWithdrawAction>> getActions(Long id);

    RestResult<?> doPay(String ids);

    void export(AdminUser adminUser, IndexWrapper wrapper, HttpServletResponse response) throws IOException;

    RestResult<?> updateBankInfo(UpdateBankInfoWrapper updateBankInfoWrapper);

    /**
     * 提现操作
     *
     * @param id 为空时表示批量操作
     * @return
     */
    RestResult remit(Long id);

    RestResult remitHistory(Long id);

    RestResult receiptFileDownload(Long id);

    RestResult deleteById(Long id);

    RestResult getAutoWithdrawAmount();

    RestResult updateAutoWithdrawAmount(String amount);

    List<Long> getDriverIds(List<Long> cans, List<Long> coms);
}
